<%@ page contentType="text/html; charset=utf-8"%>
<%
	String path = request.getContextPath();
	String reloginPath = path + "/home/index.do";
	Boolean verifycodeError = (Boolean) request.getAttribute("verifycodeError");
%>
<html>
	<head>
		<style type="text/css">
.logonBox-input {
	height: 20px;
	width: 150px;
	line-height: 14px;
	background: #FFF;
	font-family: "宋体", Arial;
	border: 1px solid #899db4;
	padding: 2px;
	font-size: 12;
}

.logonBox-button {
	width: 77px;
	height: 28px;
	background: url(../images/default_button_logon.gif) no-repeat left top;
	color: #3e82a6;
	border: 0px none;
	padding-top: 3px;
}

.logonBox-button-hover {
	width: 77px;
	height: 28px;
	background: url(../images/default_button_logon_hover.gif) no-repeat left
		top;
	color: #3e82a6;
	border: 0px none;
	padding-top: 3px;
}

.logonBox-button-active {
	width: 77px;
	height: 28px;
	background: url(../images/default_button_logon_active.gif) no-repeat
		left top;
	color: #3e82a6;
	border: 0px none;
	padding-top: 3px;
}
</style>
		<title>登录入口</title>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<script language="JavaScript" type="text/javascript">
var Logon = {
	checkUserInfo : function() {
		var verifycodeBox = document.getElementById("verifycode");
		if (verifycodeBox.value == "") {
			document.getElementById("verifyNull").style.display = "block";
			if (document.getElementById("verifyError") != null) {
				document.getElementById("verifyError").style.display = "none";
			}
			verifycodeBox.focus();
			return false;
		} else {
			document.getElementById("form1").submit();
			return true;
		}
	},

	buttonEvent : function(element, event) {
		if (element == null)
			return;
		switch (event.type) {
		case "mouseover":
			element.className = "logonBox-button-hover";
			break;
		case "mouseout":
			element.className = "logonBox-button";
			break;
		case "mousedown":
			element.className = "logonBox-button-active";
			break;
		case "mouseup":
			element.className = "logonBox-button";
			break;
		}
	}
};

function logout() {
	location.href = "logoff.do";
};
</script>
	</head>
	<body>
		<table width="100%" height="100%" border="0" cellpadding="0"
			cellspacing="0">
			<input type="hidden" value=<%=path%> id="path" />
			<tr>
				<td style="background-color: #f3f8fb;">
					<table width="370" height="250" border="0" align="center"
						cellpadding="0" cellspacing="0">
						<tr>
							<td background="../images/default_logon_bg01.gif">
								<form id="form1" name="form1" method="post"
									onSubmit="return Logon.checkUserInfo();" action="checkVerifycode.do">
									<table width="100%" border="0" cellpadding="0" cellspacing="0">
										<tr>
											<td width="21%" height="41">
												&nbsp;
											</td>
											<td width="14%">
												&nbsp;
											</td>
											<td width="65%">
												&nbsp;
											</td>
										</tr>
										<%
											if (Boolean.TRUE.equals(verifycodeError)) {
										%>
										<tr id="verifyError" style="display: block">
											<td id="message" colspan="3" height="20" align="center"
												style="color: red; font-size: 12">
												验证码错误！
											</td>
										</tr>
										<%
											}
										%>
										<tr id="verifyNull" style="display: none">
											<td id="message" colspan="3" height="30" align="center"
												style="color: red; font-size: 12">
												请输入验证码！
											</td>
										</tr>
										<tr>
											<td height="38">
												&nbsp;
											</td>
											<td style="color: #0a4572; font-size: 12">
												验证码：
											</td>
											<td>
												<input class="logonBox-input" id="verifycode"
													name="verifycode" maxlength="6" type="text" />
											</td>
										</tr>
										<tr>
											<td height="40" colspan="3"
												style="padding-left: 40px; font-size: 12">
												若长时间未收到验证码，请点击
												<a href="javascript:logout()">退出登录</a>，重新登录。
											</td>
										</tr>
										<tr>
											<td>
												&nbsp;
											</td>
											<td>
												&nbsp;
											</td>
											<td style="padding-left: 77px;">
												<button type="submit" class="logonBox-button"
													onMouseOver="Logon.buttonEvent(this, event)"
													onMouseOut="Logon.buttonEvent(this, event)"
													onMouseDown="Logon.buttonEvent(this, event)"
													onMouseUp="Logon.buttonEvent(this, event)"></button>
											</td>
										</tr>
									</table>
								</form>
							</td>
						</tr>
					</table>
				</td>
			</tr>
			<tr>
				<td height="25" align="right"
					style="padding-right: 40px; font-family: '宋体', Arial; border-top: 1px solid #90b2ca; background: #c1dcf1; color: #0a4572; filter: dropshadow(color = #FFFFFF, offx = 1, offy = 1);">
					为获得更好的用户体验，建议使用IE6浏览器&nbsp;&nbsp;&nbsp;中国移动数据业务运营支撑中心
				</td>
			</tr>
		</table>
	</body>
</html>
